package com.qcby.service.Impl;

import com.qcby.dao.UserMapper;
import com.qcby.entity.User;
import com.qcby.service.UserLoginService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

/**
 * Created with IntelliJ IDEA.
 *
 * @Author: Tom
 * @Date: 2021/07/20/10:14
 * @Description:
 */
@Service
public class UserLoginServiceImpl implements UserLoginService {
  @Autowired
  private UserMapper userMapper;
  @Override
  public User judgeIn(User user) {
      User u = userMapper.selectByUserInfo(user);
      return u;
  }

  @Override
  public int register(User user) {
    int t = userMapper.insert(user);
    return t;
  }
}
